import { BasicColumn, FormSchema } from '/@/components/Table';
import { checkName } from '/@/utils/index';
// import { asyncRoutes } from '/@/router/routes';
// import { transformRouteToMenu } from '/@/router/helper/menuHelper';

export const columns: BasicColumn[] = [
  {
    title: '角色名称',
    dataIndex: 'Name',
    // width: 200,
  },
  // {
  //   title: '角色值',
  //   dataIndex: 'roleValue',
  //   width: 180,
  // },
  // {
  //   title: '排序',
  //   dataIndex: 'orderNo',
  //   width: 50,
  // },
  // {
  //   title: '创建时间',
  //   dataIndex: 'createTime',
  //   width: 180,
  // },
  {
    title: '描述',
    dataIndex: 'Description',
  },
];

export const formSchema: FormSchema[] = [
  {
    field: 'Name',
    label: '角色名称',
    rules: [
      {
        required: true,
        validator: async (_rule, value) => checkName(value, `角色名称`),
        trigger: ['change', 'blur'],
      },
    ],
    componentProps: {
      disabled: false,
    },
    component: 'Input',
  },

  {
    label: '描述',
    field: 'Description',
    component: 'InputTextArea',
  },
  {
    label: ' ',
    field: 'FunctionMenu',
    slot: 'menu',
    component: 'Input',
  },
];

export const menuList = [
  {
    id: '1',
    component: 'LAYOUT',
    type: '1',
    icon: 'material-symbols:home-app-logo',
    menuName: '主页',
    permission: '',
    children: [],
  },
  {
    id: '2',
    component: 'LAYOUT',
    type: '1',
    icon: 'mdi:view-module',
    menuName: '基础模块',
    permission: '',
    children: [
      {
        id: '2-1',
        component: '/project/enterpriseModel/index',
        type: '2',
        menuName: '企业模型',
        permission: '',
        children: [
          {
            id: '2-1-addFather',
            type: 'btn',
            menuName: '按钮-新增父级',
            permission: '',
          },
          {
            id: '2-1-addChild',
            type: 'btn',
            menuName: '按钮-新增子级',
            permission: '',
          },
          {
            id: '2-1-save',
            type: 'btn',
            menuName: '按钮-保存',
            permission: '',
          },
          {
            id: '2-1-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
        ],
      },
      {
        id: '2-2',
        component: '/project/system/role/index',
        type: '2',
        menuName: '角色管理',
        permission: '',
        children: [
          {
            id: '2-2-add',
            type: 'btn',
            menuName: '按钮-新增角色',
            permission: '',
          },
          {
            id: '2-2-update',
            type: 'btn',
            menuName: '按钮-编辑',
            permission: '',
          },
          {
            id: '2-2-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
        ],
      },
      {
        id: '2-3',
        component: '/project/system/account/index',
        type: '2',
        menuName: '用户管理',
        permission: '',
        children: [
          {
            id: '2-3-add',
            type: 'btn',
            menuName: '按钮-新增账号',
            permission: '',
          },
          {
            id: '2-3-update',
            type: 'btn',
            menuName: '按钮-修改角色',
            permission: '',
          },
          {
            id: '2-3-password',
            type: 'btn',
            menuName: '按钮-修改密码',
            permission: '',
          },
          {
            id: '2-3-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
        ],
      },
    ],
  },
  {
    id: '3',
    component: 'LAYOUT',
    type: '1',
    icon: 'mdi:washing-machine',
    menuName: '设备管理',
    permission: '',
    children: [
      {
        id: '3-1',
        component: '/project/equipmentLedger/index.vue',
        type: '2',
        menuName: '设备台账',
        permission: '',
        children: [
          {
            id: '3-1-mesAddress',
            type: 'btn',
            menuName: '按钮-MES地址配置',
            permission: '',
          },
          {
            id: '3-1-mesSynchronize',
            type: 'btn',
            menuName: '按钮-同步MES数据',
            permission: '',
          },
          {
            id: '3-1-clear',
            type: 'btn',
            menuName: '按钮-清空',
            permission: '',
          },
          {
            id: '3-1-add',
            type: 'btn',
            menuName: '按钮-新增',
            permission: '',
          },
          {
            id: '3-1-batchDel',
            type: 'btn',
            menuName: '按钮-批量删除',
            permission: '',
          },
          {
            id: '3-1-save',
            type: 'btn',
            menuName: '按钮-保存到配置文件',
            permission: '',
          },
          {
            id: '3-1-update',
            type: 'btn',
            menuName: '按钮-编辑',
            permission: '',
          },
          {
            id: '3-1-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
        ],
      },
      {
        id: '3-2',
        component: '/project/equipmentModel/index',
        type: '2',
        menuName: '设备型号',
        permission: '',
        children: [
          {
            id: '3-2-add',
            type: 'btn',
            menuName: '按钮-新增',
            permission: '',
          },
          {
            id: '3-2-upload',
            type: 'btn',
            menuName: '按钮-导入',
            permission: '',
          },
          {
            id: '3-2-import',
            type: 'btn',
            menuName: '按钮-导出',
            permission: '',
          },
          {
            id: '3-2-edit',
            type: 'btn',
            menuName: '按钮-编辑',
            permission: '',
          },
          {
            id: '3-2-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
        ],
      },
      {
        id: '3-3',
        component: '/project/equipmentType/index.vue',
        type: '2',
        menuName: '设备类型',
        permission: '',
        children: [
          {
            id: '3-3-add',
            type: 'btn',
            menuName: '按钮-新增',
            permission: '',
          },
          {
            id: '3-3-upload',
            type: 'btn',
            menuName: '按钮-导入',
            permission: '',
          },
          {
            id: '3-3-import',
            type: 'btn',
            menuName: '按钮-导出',
            permission: '',
          },
          {
            id: '3-3-edit',
            type: 'btn',
            menuName: '按钮-编辑',
            permission: '',
          },
          {
            id: '3-3-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
        ],
      },
    ],
  },
  {
    id: '4',
    component: 'LAYOUT',
    type: '1',
    icon: 'ant-design:cluster-outlined',
    menuName: '设备集成',
    permission: '',
    children: [
      {
        id: '4-1',
        component: '/project/tag/index',
        type: '2',
        menuName: '设备接入',
        permission: '',
        children: [
          {
            id: '4-1-addDevice',
            type: 'btn',
            menuName: '按钮-新增设备',
            permission: '',
          },
          {
            id: '4-1-addNode',
            type: 'btn',
            menuName: '按钮-新增节点',
            permission: '',
          },
          {
            id: '4-1-addGroup',
            type: 'btn',
            menuName: '按钮-新增分组',
            permission: '',
          },
          {
            id: '4-1-addTemplate',
            type: 'btn',
            menuName: '按钮-新增模板',
            permission: '',
          },
          {
            id: '4-1-exportDevice',
            type: 'btn',
            menuName: '按钮-导出设备',
            permission: '',
          },
          {
            id: '4-1-exportGroup',
            type: 'btn',
            menuName: '按钮-导出分组',
            permission: '',
          },
          {
            id: '4-1-updateNode',
            type: 'btn',
            menuName: '按钮-编辑节点',
            permission: '',
          },
          {
            id: '4-1-updateDevice',
            type: 'btn',
            menuName: '按钮-编辑设备',
            permission: '',
          },
          {
            id: '4-1-updateGroup',
            type: 'btn',
            menuName: '按钮-编辑分组',
            permission: '',
          },
          {
            id: '4-1-moveDevice',
            type: 'btn',
            menuName: '按钮-移动设备',
            permission: '',
          },
          {
            id: '4-1-delNode',
            type: 'btn',
            menuName: '按钮-删除节点',
            permission: '',
          },
          {
            id: '4-1-delDevice',
            type: 'btn',
            menuName: '按钮-删除设备',
            permission: '',
          },
          {
            id: '4-1-delGroup',
            type: 'btn',
            menuName: '按钮-删除分组',
            permission: '',
          },
          {
            id: '4-1-upload',
            type: 'btn',
            menuName: '按钮-导入',
            permission: '',
          },
          {
            id: '4-1-add',
            type: 'btn',
            menuName: '按钮-新增',
            permission: '',
          },
          {
            id: '4-1-batchAdd',
            type: 'btn',
            menuName: '按钮-批量新增',
            permission: '',
          },
          {
            id: '4-1-batchDel',
            type: 'btn',
            menuName: '按钮-批量删除',
            permission: '',
          },
          {
            id: '4-1-save',
            type: 'btn',
            menuName: '按钮-保存到配置文件',
            permission: '',
          },
          {
            id: '4-1-update',
            type: 'btn',
            menuName: '按钮-编辑',
            permission: '',
          },
          {
            id: '4-1-code',
            type: 'btn',
            menuName: '按钮-数据转换',
            permission: '',
          },
          {
            id: '4-1-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
          {
            id: '4-1-copy',
            type: 'btn',
            menuName: '按钮-复制',
            permission: '',
          },
        ],
      },
      {
        id: '4-2',
        component: '/project/templateManagement/index',
        type: '2',
        menuName: '设备模型',
        permission: '',
        children: [
          {
            id: '4-2-save',
            type: 'btn',
            menuName: '按钮-保存到配置文件',
            permission: '',
          },
          {
            id: '4-2-add',
            type: 'btn',
            menuName: '按钮-新增设备',
            permission: '',
          },
          {
            id: '4-2-update',
            type: 'btn',
            menuName: '按钮-编辑',
            permission: '',
          },
          {
            id: '4-2-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
        ],
      },
    ],
  },
  {
    id: '5',
    component: 'LAYOUT',
    type: '0',
    menuName: '网关管理',
    permission: '',
    children: [
      {
        id: '5-1-add',
        type: 'btn',
        menuName: '按钮-新增节点',
        permission: '',
      },
      {
        id: '5-1-download',
        type: 'btn',
        menuName: '按钮-下载工程',
        permission: '',
      },
      {
        id: '5-1-upload',
        type: 'btn',
        menuName: '按钮-上传工程',
        permission: '',
      },
      {
        id: '5-1-look',
        type: 'btn',
        menuName: '按钮-详情',
        permission: '',
      },
      {
        id: '5-1-restart',
        type: 'btn',
        menuName: '按钮-重启节点',
        permission: '',
      },
      {
        id: '5-1-update',
        type: 'btn',
        menuName: '按钮-软件更新',
        permission: '',
      },
    ],
  },
  {
    id: '6',
    component: 'LAYOUT',
    type: '1',
    icon: 'mdi:robot-industrial-outline',
    menuName: '物联呈现',
    permission: '',
    children: [
      {
        id: '6-1',
        component: '/project/equipmentCard/index',
        type: '2',
        menuName: '设备卡片',
        permission: '',
        children: [],
      },
      {
        id: '6-2',
        component: 'project/equipmentStatus/index',
        type: '2',
        menuName: '设备状态',
        permission: '',
        children: [
          {
            id: '6-2-import',
            type: 'btn',
            menuName: '按钮-导出',
            permission: '',
          },
          {
            id: '6-2-detail',
            type: 'btn',
            menuName: '按钮-详情',
            permission: '',
          },
        ],
      },
      {
        id: '6-3',
        component: '/project/eqIntegration/index',
        type: '2',
        menuName: '实时工况',
        permission: '',
        children: [
          {
            id: '6-3-lookDevice',
            type: 'btn',
            menuName: '按钮-查看设备',
            permission: '',
          },
          {
            id: '6-3-lookGroup',
            type: 'btn',
            menuName: '按钮-查看分组',
            permission: '',
          },
        ],
      },
      {
        id: '6-4',
        component: '/project/diagnosis/index',
        type: '2',
        menuName: '设备工况',
        permission: '',
      },
    ],
  },
  {
    id: '7',
    component: 'LAYOUT',
    type: '1',
    icon: 'mdi:application-export',
    menuName: '数据应用',
    permission: '',
    children: [
      {
        id: '7-2',
        component: '/project/formula/index',
        type: '2',
        menuName: '配方管理',
        permission: '',
        children: [
          {
            id: '7-2-add',
            type: 'btn',
            menuName: '按钮-新增配方',
            permission: '',
          },
          {
            id: '7-2-save',
            type: 'btn',
            menuName: '按钮-保存到配置文件',
            permission: '',
          },
          {
            id: '7-2-update',
            type: 'btn',
            menuName: '按钮-编辑配方',
            permission: '',
          },
          {
            id: '7-2-lookElement',
            type: 'btn',
            menuName: '按钮-查看成分',
            permission: '',
          },
          {
            id: '7-2-lookProduct',
            type: 'btn',
            menuName: '按钮-查看产品',
            permission: '',
          },
          {
            id: '7-2-copy',
            type: 'btn',
            menuName: '按钮-复制配方',
            permission: '',
          },
          {
            id: '7-2-del',
            type: 'btn',
            menuName: '按钮-删除配方',
            permission: '',
          },
          {
            id: '7-2-batchDel',
            type: 'btn',
            menuName: '按钮-批量删除配方',
            permission: '',
          },
          {
            id: '7-2-addProductElement',
            type: 'btn',
            menuName: '按钮-新增产品成分',
            permission: '',
          },
          {
            id: '7-2-updateProductElement',
            type: 'btn',
            menuName: '按钮-编辑产品成分',
            permission: '',
          },
          {
            id: '7-2-delProductElement',
            type: 'btn',
            menuName: '按钮-删除产品成分',
            permission: '',
          },
          {
            id: '7-2-addProduct',
            type: 'btn',
            menuName: '按钮-新增配方产品',
            permission: '',
          },
          {
            id: '7-2-updateProduct',
            type: 'btn',
            menuName: '按钮-编辑配方产品',
            permission: '',
          },
          {
            id: '7-2-delProduct',
            type: 'btn',
            menuName: '按钮-删除配方产品',
            permission: '',
          },
          {
            id: '7-2-lookProductElement',
            type: 'btn',
            menuName: '按钮-查看配方产品成分',
            permission: '',
          },
          {
            id: '7-2-updateElement',
            type: 'btn',
            menuName: '按钮-删除配方成分',
            permission: '',
          },
        ],
      },
    ],
  },
  {
    id: '8',
    component: 'LAYOUT',
    type: '1',
    menuName: '报警管理',
    permission: '',
    children: [
      {
        id: '8-1',
        component: '/project/alertRules/home',
        type: '2',
        menuName: '报警首页',
        permission: '',
        children: [],
      },
      {
        id: '8-2',
        component: '/project/alertRules/statistics',
        type: '2',
        menuName: '报警统计',
        permission: '',
        children: [],
      },
      {
        id: '8-3',
        component: '/project/alertRules/record',
        type: '2',
        menuName: '报警明细',
        permission: '',
        children: [],
      },
      {
        id: '8-4',
        component: '/project/alertRules/index',
        type: '2',
        menuName: '报警配置',
        permission: '',
        children: [
          {
            id: '8-4-4-addGroup',
            type: 'btn',
            menuName: '按钮-新增分组',
            permission: '',
          },
          {
            id: '8-4-4-updateGroup',
            type: 'btn',
            menuName: '按钮-编辑分组',
            permission: '',
          },
          {
            id: '8-4-4-delGroup',
            type: 'btn',
            menuName: '按钮-删除分组',
            permission: '',
          },

          {
            id: '8-4-4-add',
            type: 'btn',
            menuName: '按钮-新增告警',
            permission: '',
          },
          {
            id: '8-4-4-save',
            type: 'btn',
            menuName: '按钮-保存到配置文件',
            permission: '',
          },
          {
            id: '8-4-4-lookRule',
            type: 'btn',
            menuName: '按钮-查看告警规则',
            permission: '',
          },
          {
            id: '8-4-4-update',
            type: 'btn',
            menuName: '按钮-编辑告警',
            permission: '',
          },
          {
            id: '8-4-4-del',
            type: 'btn',
            menuName: '按钮-删除告警',
            permission: '',
          },
          {
            id: '8-4-4-addRule',
            type: 'btn',
            menuName: '按钮-修改告警规则',
            permission: '',
          },
        ],
      },
      {
        id: '8-5',
        component: '/project/alertRules/diagnosis',
        type: '2',
        menuName: '远程诊断',
        permission: '',
        children: [],
      },
    ],
  },
  {
    id: '9',
    component: 'LAYOUT',
    type: '1',
    menuName: '设备控制',
    permission: '',
    children: [
      {
        id: '9-1',
        component: '/project/equipmentControl/issued',
        type: '2',
        menuName: '指令下发',
        permission: '',
        children: [],
      },
      {
        id: '9-2',
        component: '/project/equipmentControl/journal',
        type: '2',
        menuName: '指令下发日志',
        permission: '',
        children: [],
      },
    ],
  },
  {
    id: '10',
    component: 'LAYOUT',
    type: '1',
    menuName: 'API',
    permission: '',
    children: [
      {
        id: '10-1',
        component: '/project/rabbit/index',
        type: '2',
        menuName: 'RabbitMQ服务',
        permission: '',
        children: [
          {
            id: '10-1-addServer',
            type: 'btn',
            menuName: '按钮-新增主机',
            permission: '',
          },
          {
            id: '10-1-addGroup',
            type: 'btn',
            menuName: '按钮-新增通道',
            permission: '',
          },
          {
            id: '10-1-lookServer',
            type: 'btn',
            menuName: '按钮-查看服务',
            permission: '',
          },
          {
            id: '10-1-updateServer',
            type: 'btn',
            menuName: '按钮-编辑主机',
            permission: '',
          },
          {
            id: '10-1-updateGroup',
            type: 'btn',
            menuName: '按钮-编辑通道',
            permission: '',
          },
          {
            id: '10-1-delServer',
            type: 'btn',
            menuName: '按钮-删除主机',
            permission: '',
          },
          {
            id: '10-1-delGroup',
            type: 'btn',
            menuName: '按钮-删除通道',
            permission: '',
          },
          {
            id: '10-1-add',
            type: 'btn',
            menuName: '按钮-新增',
            permission: '',
          },
          {
            id: '10-1-save',
            type: 'btn',
            menuName: '按钮-保存到配置文件',
            permission: '',
          },
          {
            id: '10-1-look',
            type: 'btn',
            menuName: '按钮-查看',
            permission: '',
          },
          {
            id: '10-1-update',
            type: 'btn',
            menuName: '按钮-编辑',
            permission: '',
          },
          {
            id: '10-1-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
          {
            id: '10-1-copy',
            type: 'btn',
            menuName: '按钮-复制',
            permission: '',
          },
        ],
      },
      {
        id: '10-2',
        component: '/project/rabbit/mqtt',
        type: '2',
        menuName: 'MQTT服务',
        permission: '',
        children: [
          {
            id: '10-2-addServer',
            type: 'btn',
            menuName: '按钮-新增主机',
            permission: '',
          },
          {
            id: '10-2-addGroup',
            type: 'btn',
            menuName: '按钮-新增分组',
            permission: '',
          },
          {
            id: '10-2-lookServer',
            type: 'btn',
            menuName: '按钮-查看主机',
            permission: '',
          },
          {
            id: '10-2-updateServer',
            type: 'btn',
            menuName: '按钮-编辑主机',
            permission: '',
          },
          {
            id: '10-2-updateGroup',
            type: 'btn',
            menuName: '按钮-编辑分组',
            permission: '',
          },
          {
            id: '10-2-delServer',
            type: 'btn',
            menuName: '按钮-删除主机',
            permission: '',
          },
          {
            id: '10-2-delGroup',
            type: 'btn',
            menuName: '按钮-删除分组',
            permission: '',
          },
          {
            id: '10-2-look',
            type: 'btn',
            menuName: '按钮-查看',
            permission: '',
          },
          {
            id: '10-2-update',
            type: 'btn',
            menuName: '按钮-编辑',
            permission: '',
          },
          {
            id: '10-2-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
          {
            id: '10-2-copy',
            type: 'btn',
            menuName: '按钮-复制',
            permission: '',
          },
          {
            id: '10-2-add',
            type: 'btn',
            menuName: '按钮-新增',
            permission: '',
          },
          {
            id: '10-2-save',
            type: 'btn',
            menuName: '按钮-保存',
            permission: '',
          },
        ],
      },
      {
        id: '10-3',
        component: '/iFrames/FrameBlank',
        type: '2',
        menuName: 'WebApi',
        permission: '',
      },
    ],
  },
  {
    id: '11',
    component: 'LAYOUT',
    type: '1',
    menuName: '数据归档',
    permission: '',
    children: [
      {
        id: '11-1',
        component: '/project/dataArchiving/form',
        type: '2',
        menuName: '配置',
        permission: '',
        children: [
          {
            id: '11-1-reset',
            type: 'btn',
            menuName: '按钮-重置',
            permission: '',
          },
          {
            id: '11-1-save',
            type: 'btn',
            menuName: '按钮-保存',
            permission: '',
          },
        ],
      },
      {
        id: '11-2',
        component: '/project/dataArchiving/index',
        type: '2',
        menuName: '数据查询',
        permission: '',
      },
      {
        id: '11-3',
        component: '/project/dataArchiving/linkedDataStorage/index',
        type: '2',
        menuName: '关联数据存储',
        permission: '',
        children: [
          {
            id: '11-3-addGroup',
            type: 'btn',
            menuName: '按钮-新增分组',
            permission: '',
          },
          {
            id: '11-3-updateGroup',
            type: 'btn',
            menuName: '按钮-编辑分组',
            permission: '',
          },
          {
            id: '11-3-delGroup',
            type: 'btn',
            menuName: '按钮-删除分组',
            permission: '',
          },

          {
            id: '11-3-add',
            type: 'btn',
            menuName: '按钮-新增关联数据存储',
            permission: '',
          },
          {
            id: '11-3-save',
            type: 'btn',
            menuName: '按钮-保存到配置文件',
            permission: '',
          },
          {
            id: '11-3-copy',
            type: 'btn',
            menuName: '按钮-复制关联数据存储',
            permission: '',
          },
          {
            id: '11-3-update',
            type: 'btn',
            menuName: '按钮-编辑关联数据存储',
            permission: '',
          },
          {
            id: '11-3-del',
            type: 'btn',
            menuName: '按钮-删除关联数据存储',
            permission: '',
          },
        ],
      },
    ],
  },
  {
    id: '12',
    component: 'LAYOUT',
    type: '1',
    menuName: '系统运维',
    permission: '',
    children: [
      {
        id: '12-1',
        component: '/project/system/convention',
        type: '2',
        menuName: '基础配置',
        permission: '',
        children: [
          {
            id: '12-1-reset',
            type: 'btn',
            menuName: '按钮-重置',
            permission: '',
          },
          {
            id: '12-1-save',
            type: 'btn',
            menuName: '按钮-提交',
            permission: '',
          },
        ],
      },
      {
        id: '12-2',
        component: '/project/system/devOps',
        type: '2',
        menuName: '授权',
        permission: '',
        children: [
          {
            id: '12-2-reset',
            type: 'btn',
            menuName: '按钮-重置',
            permission: '',
          },
          {
            id: '12-2-save',
            type: 'btn',
            menuName: '按钮-提交',
            permission: '',
          },
        ],
      },
      {
        id: '12-3',
        component: '/project/engineering/index',
        type: '2',
        menuName: '工程管理',
        permission: '',
        children: [
          {
            id: '12-3-add',
            type: 'btn',
            menuName: '按钮-新增',
            permission: '',
          },
          {
            id: '12-3-load',
            type: 'btn',
            menuName: '按钮-加载',
            permission: '',
          },
          {
            id: '12-3-del',
            type: 'btn',
            menuName: '按钮-删除',
            permission: '',
          },
        ],
      },
      {
        id: '12-4',
        component: 'LAYOUT',
        type: '2',
        menuName: '连接资源',
        permission: '',
        children: [
          {
            id: '12-4-1',
            component: '/project/database/index',
            type: '3',
            menuName: '数据库连接',
            permission: '',
            children: [
              {
                id: '12-4-1-add',
                type: 'btn',
                menuName: '按钮-新增',
                permission: '',
              },
              {
                id: '12-4-1-save',
                type: 'btn',
                menuName: '按钮-保存到配置文件',
                permission: '',
              },
              {
                id: '12-4-1-update',
                type: 'btn',
                menuName: '按钮-编辑',
                permission: '',
              },
              {
                id: '12-4-1-del',
                type: 'btn',
                menuName: '按钮-删除',
                permission: '',
              },
            ],
          },
          {
            id: '12-4-2',
            component: '/project/mes/index',
            type: '3',
            menuName: 'MES服务配置',
            permission: '',
            children: [
              {
                id: '12-4-2-add',
                type: 'btn',
                menuName: '按钮-新增',
                permission: '',
              },
              {
                id: '12-4-2-save',
                type: 'btn',
                menuName: '按钮-保存到配置文件',
                permission: '',
              },
              {
                id: '12-4-2-update',
                type: 'btn',
                menuName: '按钮-编辑',
                permission: '',
              },
              {
                id: '12-4-2-del',
                type: 'btn',
                menuName: '按钮-删除',
                permission: '',
              },
            ],
          },
          {
            id: '12-4-3',
            component: '/project/mesDocking/index',
            type: '3',
            menuName: 'MES数据推送',
            permission: '',
            children: [
              {
                id: '12-4-3-save',
                type: 'btn',
                menuName: '按钮-保存',
                permission: '',
              },
              {
                id: '12-4-3-reset',
                type: 'btn',
                menuName: '按钮-重置',
                permission: '',
              },
            ],
          },
          {
            id: '12-4-4',
            component: '/project/butlerDocking/index',
            type: '3',
            menuName: '管家数据推送',
            permission: '',
            children: [
              {
                id: '12-4-4-save',
                type: 'btn',
                menuName: '按钮-保存',
                permission: '',
              },
              {
                id: '12-4-4-reset',
                type: 'btn',
                menuName: '按钮-重置',
                permission: '',
              },
            ],
          },
        ],
      },
    ],
  },
  
  {
    id: '20',
    component: 'LAYOUT',
    type: '1',
    menuName: '大屏设计',
    permission: '',
    children: [],
  },
];

// 获取菜单
export async function getMenuList() {
  // const WHITE_NAME_LIST = ['About', 'PageNotFound'];
  // 过滤白名单
  // const routerPro = asyncRoutes.filter((item) => WHITE_NAME_LIST.indexOf(item.name) === -1);
  //  路由到菜单结构
  // const backMenuList = transformRouteToMenu(menuList);
  // eachMenu(backMenuList);
  // backMenuList.sort((a, b) => {
  //   return (a.orderNo || 0) - (b.orderNo || 0);
  // });
  return menuList;
}
